﻿using System;
using System.Collections.Generic;
using System.Text;

namespace Octopus.Logging
{
    [Serializable]
    public class LogException:Exception
    {
        public static readonly string ConfigRootNull = "日志配置错误：根节点不存在";
        public static readonly string ConfigGlobalNull = "日志配置错误：全局配置项不存在";
        public static readonly string ConfigGlobalEmpty = "日志配置错误：全局配置项过少";
        public static readonly string ConfigItemDuplication = "日志配置错误：配置项重复";
        public static readonly string ConfigIDNull = "日志配置错误：ID属性未设置";
        public static readonly string ConfigNameNull = "日志配置：Name属性未配置";
        public static readonly string ConfigAssemblyDeformity = "日志配置错误：程序集设置不全";
        public static readonly string ConfigAssemblyParamNameNull = "日志配置：程序集参数名称为空";
        public static readonly string ConfigAssemblyParamDuplication = "日志配置：程序集参数名称重复";
        public static readonly string ConfigBusinessStructureNull = "日志配置：业务模块结构未配置";       

        public static readonly string CodingParamNull = "日志使用错误：ObjectType及Action不得为空";

        public static readonly string ImplInterfaceNoyet = "日志实现错误：未实现相关接口";
        public static readonly string ImplIFormatterNoyet = "日志实现错误：未实现IFormatter接口";
        public static readonly string ImplIFormatterNull = "日志实现错误：未实例化Formatter";
        public static readonly string ImplIAppenderNoyet = "日志实现错误：未实现IAppender接口";
        public static readonly string ImplIAppenderNull = "日志实现错误：未实例化Appender";

        public LogException() { }
        public LogException(string message):base(message)
        { 
        }
        public LogException(string message, string messageAppend)
            :this(message +":" + messageAppend)
        {            
        }
    }
}
